package com.hxf.dto;

import static javax.persistence.GenerationType.IDENTITY;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;

import org.hibernate.annotations.PolymorphismType;

/**
 * 地区类
 * @author tengyicheng
 *
 */
@Entity
@Table(name = "rk_area")
@org.hibernate.annotations.Entity(selectBeforeUpdate = true, dynamicInsert = true, dynamicUpdate = true, polymorphism = PolymorphismType.EXPLICIT)
public class AreaDto extends BaseDto{
	private Integer id;
	private Integer grade;
	private String abbreviation;
	private String fullName;
	private String code;
	private String remark;
	private String parentCode;
	private Integer status;
	 
	
	@Id
	@GeneratedValue(strategy = IDENTITY)
	@Column(name = "id", unique = true, nullable = false)
	public Integer getId() {
		return id;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	
	@Column(name="grade")
	public Integer getGrade() {
		return grade;
	}
	public void setGrade(int grade) {
		this.grade = grade;
	}
	
	@Column(name="abbreviation")
	public String getAbbreviation() {
		return abbreviation;
	}
	public void setAbbreviation(String abbreviation) {
		this.abbreviation = abbreviation;
	}
	
	@Column(name="full_name")
	public String getFullName() {
		return fullName;
	}
	public void setFullName(String fullName) {
		this.fullName = fullName;
	}
	
	@Column(name="code")
	public String getCode() {
		return code;
	}
	public void setCode(String code) {
		this.code = code;
	}
	
	@Column(name="remark")
	public String getRemark() {
		return remark;
	}
	public void setRemark(String remark) {
		this.remark = remark;
	}
	
	@Column(name="parent_code")
	public String getParentCode() {
		return parentCode;
	}
	public void setParentCode(String parentCode) {
		this.parentCode = parentCode;
	}
	
	@Column(name="status")
	public Integer getStatus() {
		return status;
	}
	
	public void setStatus(Integer status) {
		this.status = status;
	}
	@Override
	public String toString() {
		return "AreaDto [id=" + id + ", grade=" + grade + ", abbreviation="
				+ abbreviation + ", fullName=" + fullName + ", code=" + code
				+ ", remark=" + remark + ", parentCode=" + parentCode
				+ ", status=" + status + "]";
	}
	
}
